<?php
/**
 * Created by PhpStorm.
 * User: 12133
 * Date: 2024/3/18
 * Time: 10:02
 */

namespace app\model\admin;

class Order extends Base
{
    protected $pk = 'order_no';
    protected $append = [
        'status_text',
        'html'
    ];
    protected $status_all = [
        1 => '未审批',
        2 => '通过',
        3 => '拒绝'
    ];
    public function getStatusTextAttr($value,$data){
        return $this->status_all[$data['status']];
    }
    public function getHtmlAttr($value){
        return htmlspecialchars_decode($value);
    }
}